<template>
    <van-address-edit
  :area-list="areaList"
  show-postal
  show-set-default
  show-search-result
  :search-result="searchResult"
  :area-columns-placeholder="['请选择', '请选择', '请选择']"
  @save="onSave"
>
<!-- @change-detail="onChangeDetail" -->
<!-- show-delete -->
<!-- @delete="onDelete" -->
    <back></back>
    </van-address-edit>
</template>
<script>
import { areaList } from '@vant/area-data';
import { Toast } from 'vant';
import Back from "@/components/Back.vue";
export default {
  data() {
    return {
      areaList,
      searchResult: [],
    };
  },
  methods: {
    onSave() {
      Toast('保存成功');
      // this.$store.dispatch("ADDEDIT_DATA", result);
    },
    // onDelete() {
    //   Toast('已删除');
    // },
    // onChangeDetail(val) {
    //   if (val) {
    //     this.searchResult = [
    //       {
    //         name: '黄龙万科中心',
    //         address: '杭州市西湖区',
    //       },
    //     ];
    //   } else {
    //     this.searchResult = [];
    //   }
    // },
  },
  components:{
    Back,
  }
};
</script>
<style scoped>
  .revoke {
    bottom: 25vh;
  }
</style>